<?xml version="1.0" encoding="ascii"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
          "DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
  <title>robotide.utils</title>
  <link rel="stylesheet" href="epydoc.css" type="text/css" />
  <script type="text/javascript" src="epydoc.js"></script>
</head>

<body bgcolor="white" text="black" link="blue" vlink="#204080"
      alink="#204080">
<!-- ==================== NAVIGATION BAR ==================== -->
<table class="navbar" border="0" width="100%" cellpadding="0"
       bgcolor="#a0c0ff" cellspacing="0">
  <tr valign="middle">
  <!-- Home link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="robotide-module.html">Home</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Tree link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="module-tree.html">Trees</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Index link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="identifier-index.html">Indices</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Help link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="help.html">Help</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Project homepage -->
      <th class="navbar" align="right" width="100%">
        <table border="0" cellpadding="0" cellspacing="0">
          <tr><th class="navbar" align="center"
            ><a class="navbar" target="_top" href="http://code.google.com/p/robotframework-ride">RIDE</a></th>
          </tr></table></th>
  </tr>
</table>
<table width="100%" cellpadding="0" cellspacing="0">
  <tr valign="top">
    <td width="100%">
      <span class="breadcrumbs">
        <a href="robotide-module.html">Package&nbsp;robotide</a> ::
        Package&nbsp;utils
      </span>
    </td>
    <td>
      <table cellpadding="0" cellspacing="0">
        <!-- hide/show private -->
      </table>
    </td>
  </tr>
</table>
<h1 class="epydoc">Source Code for <a href="robotide.utils-module.html">Package robotide.utils</a></h1>
<pre class="py-src">
<a name="L1"></a><tt class="py-lineno"> 1</tt>  <tt class="py-line"><tt class="py-comment">#  Copyright 2008-2009 Nokia Siemens Networks Oyj</tt> </tt>
<a name="L2"></a><tt class="py-lineno"> 2</tt>  <tt class="py-line"><tt class="py-comment">#</tt> </tt>
<a name="L3"></a><tt class="py-lineno"> 3</tt>  <tt class="py-line"><tt class="py-comment">#  Licensed under the Apache License, Version 2.0 (the "License");</tt> </tt>
<a name="L4"></a><tt class="py-lineno"> 4</tt>  <tt class="py-line"><tt class="py-comment">#  you may not use this file except in compliance with the License.</tt> </tt>
<a name="L5"></a><tt class="py-lineno"> 5</tt>  <tt class="py-line"><tt class="py-comment">#  You may obtain a copy of the License at</tt> </tt>
<a name="L6"></a><tt class="py-lineno"> 6</tt>  <tt class="py-line"><tt class="py-comment">#</tt> </tt>
<a name="L7"></a><tt class="py-lineno"> 7</tt>  <tt class="py-line"><tt class="py-comment">#      http://www.apache.org/licenses/LICENSE-2.0</tt> </tt>
<a name="L8"></a><tt class="py-lineno"> 8</tt>  <tt class="py-line"><tt class="py-comment">#</tt> </tt>
<a name="L9"></a><tt class="py-lineno"> 9</tt>  <tt class="py-line"><tt class="py-comment">#  Unless required by applicable law or agreed to in writing, software</tt> </tt>
<a name="L10"></a><tt class="py-lineno">10</tt>  <tt class="py-line"><tt class="py-comment">#  distributed under the License is distributed on an "AS IS" BASIS,</tt> </tt>
<a name="L11"></a><tt class="py-lineno">11</tt>  <tt class="py-line"><tt class="py-comment">#  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.</tt> </tt>
<a name="L12"></a><tt class="py-lineno">12</tt>  <tt class="py-line"><tt class="py-comment">#  See the License for the specific language governing permissions and</tt> </tt>
<a name="L13"></a><tt class="py-lineno">13</tt>  <tt class="py-line"><tt class="py-comment">#  limitations under the License.</tt> </tt>
<a name="L14"></a><tt class="py-lineno">14</tt>  <tt class="py-line"> </tt>
<a name="L15"></a><tt class="py-lineno">15</tt>  <tt class="py-line"><tt class="py-keyword">import</tt> <tt class="py-name">os</tt> </tt>
<a name="L16"></a><tt class="py-lineno">16</tt>  <tt class="py-line"><tt class="py-keyword">import</tt> <tt class="py-name">sys</tt> </tt>
<a name="L17"></a><tt class="py-lineno">17</tt>  <tt class="py-line"><tt class="py-keyword">import</tt> <tt class="py-name">inspect</tt> </tt>
<a name="L18"></a><tt class="py-lineno">18</tt>  <tt class="py-line"> </tt>
<a name="L19"></a><tt class="py-lineno">19</tt>  <tt class="py-line"><tt class="py-keyword">from</tt> <tt class="py-name">robot</tt><tt class="py-op">.</tt><tt id="link-0" class="py-name" targets="Package robotide.utils=robotide.utils-module.html"><a title="robotide.utils" class="py-name" href="#" onclick="return doclink('link-0', 'utils', 'link-0');">utils</a></tt> <tt class="py-keyword">import</tt> <tt class="py-name">printable_name</tt><tt class="py-op">,</tt> <tt class="py-name">normalize</tt><tt class="py-op">,</tt> <tt class="py-name">eq</tt><tt class="py-op">,</tt> <tt class="py-name">eq_any</tt><tt class="py-op">,</tt> \ </tt>
<a name="L20"></a><tt class="py-lineno">20</tt>  <tt class="py-line">    <tt class="py-name">HtmlWriter</tt><tt class="py-op">,</tt> <tt class="py-name">NormalizedDict</tt><tt class="py-op">,</tt> <tt class="py-name">timestr_to_secs</tt><tt class="py-op">,</tt> <tt class="py-name">secs_to_timestr</tt><tt class="py-op">,</tt> <tt class="py-name">normpath</tt><tt class="py-op">,</tt>\ </tt>
<a name="L21"></a><tt class="py-lineno">21</tt>  <tt class="py-line">    <tt class="py-name">DomWrapper</tt><tt class="py-op">,</tt> <tt class="py-name">unic</tt><tt class="py-op">,</tt> <tt class="py-name">asserts</tt><tt class="py-op">,</tt> <tt class="py-name">unescape</tt><tt class="py-op">,</tt> <tt class="py-name">html_attr_escape</tt><tt class="py-op">,</tt>\ </tt>
<a name="L22"></a><tt class="py-lineno">22</tt>  <tt class="py-line">    <tt class="py-name">html_escape</tt><tt class="py-op">,</tt> <tt class="py-name">get_timestamp</tt> </tt>
<a name="L23"></a><tt class="py-lineno">23</tt>  <tt class="py-line"><tt class="py-keyword">from</tt> <tt id="link-1" class="py-name" targets="Module robotide.ui.components=robotide.ui.components-module.html,Module robotide.utils.components=robotide.utils.components-module.html"><a title="robotide.ui.components
robotide.utils.components" class="py-name" href="#" onclick="return doclink('link-1', 'components', 'link-1');">components</a></tt> <tt class="py-keyword">import</tt> <tt id="link-2" class="py-name" targets="Class robotide.utils.components.RideHtmlWindow=robotide.utils.components.RideHtmlWindow-class.html"><a title="robotide.utils.components.RideHtmlWindow" class="py-name" href="#" onclick="return doclink('link-2', 'RideHtmlWindow', 'link-2');">RideHtmlWindow</a></tt> </tt>
<a name="L24"></a><tt class="py-lineno">24</tt>  <tt class="py-line"><tt class="py-keyword">from</tt> <tt id="link-3" class="py-name" targets="Module robotide.utils.eventhandler=robotide.utils.eventhandler-module.html"><a title="robotide.utils.eventhandler" class="py-name" href="#" onclick="return doclink('link-3', 'eventhandler', 'link-3');">eventhandler</a></tt> <tt class="py-keyword">import</tt> <tt id="link-4" class="py-name" targets="Class robotide.utils.eventhandler.RideEventHandler=robotide.utils.eventhandler.RideEventHandler-class.html"><a title="robotide.utils.eventhandler.RideEventHandler" class="py-name" href="#" onclick="return doclink('link-4', 'RideEventHandler', 'link-4');">RideEventHandler</a></tt> </tt>
<a name="L25"></a><tt class="py-lineno">25</tt>  <tt class="py-line"><tt class="py-keyword">from</tt> <tt id="link-5" class="py-name" targets="Module robotide.utils.variablematcher=robotide.utils.variablematcher-module.html"><a title="robotide.utils.variablematcher" class="py-name" href="#" onclick="return doclink('link-5', 'variablematcher', 'link-5');">variablematcher</a></tt> <tt class="py-keyword">import</tt> <tt id="link-6" class="py-name" targets="Variable robotide.ui.tree.VariableHandler.is_variable=robotide.ui.tree.VariableHandler-class.html#is_variable,Function robotide.utils.variablematcher.is_variable()=robotide.utils.variablematcher-module.html#is_variable"><a title="robotide.ui.tree.VariableHandler.is_variable
robotide.utils.variablematcher.is_variable" class="py-name" href="#" onclick="return doclink('link-6', 'is_variable', 'link-6');">is_variable</a></tt><tt class="py-op">,</tt> <tt id="link-7" class="py-name" targets="Function robotide.utils.variablematcher.is_scalar_variable()=robotide.utils.variablematcher-module.html#is_scalar_variable"><a title="robotide.utils.variablematcher.is_scalar_variable" class="py-name" href="#" onclick="return doclink('link-7', 'is_scalar_variable', 'link-7');">is_scalar_variable</a></tt><tt class="py-op">,</tt> <tt id="link-8" class="py-name" targets="Function robotide.utils.variablematcher.is_list_variable()=robotide.utils.variablematcher-module.html#is_list_variable"><a title="robotide.utils.variablematcher.is_list_variable" class="py-name" href="#" onclick="return doclink('link-8', 'is_list_variable', 'link-8');">is_list_variable</a></tt><tt class="py-op">,</tt> \ </tt>
<a name="L26"></a><tt class="py-lineno">26</tt>  <tt class="py-line">    <tt id="link-9" class="py-name" targets="Function robotide.utils.variablematcher.get_variable()=robotide.utils.variablematcher-module.html#get_variable"><a title="robotide.utils.variablematcher.get_variable" class="py-name" href="#" onclick="return doclink('link-9', 'get_variable', 'link-9');">get_variable</a></tt><tt class="py-op">,</tt> <tt id="link-10" class="py-name" targets="Function robotide.utils.variablematcher.get_variable_basename()=robotide.utils.variablematcher-module.html#get_variable_basename"><a title="robotide.utils.variablematcher.get_variable_basename" class="py-name" href="#" onclick="return doclink('link-10', 'get_variable_basename', 'link-10');">get_variable_basename</a></tt><tt class="py-op">,</tt> <tt id="link-11" class="py-name" targets="Function robotide.utils.variablematcher.find_variable_basenames()=robotide.utils.variablematcher-module.html#find_variable_basenames"><a title="robotide.utils.variablematcher.find_variable_basenames" class="py-name" href="#" onclick="return doclink('link-11', 'find_variable_basenames', 'link-11');">find_variable_basenames</a></tt> </tt>
<a name="L27"></a><tt class="py-lineno">27</tt>  <tt class="py-line"><tt class="py-keyword">from</tt> <tt id="link-12" class="py-name" targets="Module robotide.utils.highlightmatcher=robotide.utils.highlightmatcher-module.html"><a title="robotide.utils.highlightmatcher" class="py-name" href="#" onclick="return doclink('link-12', 'highlightmatcher', 'link-12');">highlightmatcher</a></tt> <tt class="py-keyword">import</tt> <tt id="link-13" class="py-name" targets="Function robotide.utils.highlightmatcher.highlight_matcher()=robotide.utils.highlightmatcher-module.html#highlight_matcher"><a title="robotide.utils.highlightmatcher.highlight_matcher" class="py-name" href="#" onclick="return doclink('link-13', 'highlight_matcher', 'link-13');">highlight_matcher</a></tt> </tt>
<a name="L28"></a><tt class="py-lineno">28</tt>  <tt class="py-line"><tt class="py-keyword">from</tt> <tt id="link-14" class="py-name" targets="Module robotide.utils.printing=robotide.utils.printing-module.html"><a title="robotide.utils.printing" class="py-name" href="#" onclick="return doclink('link-14', 'printing', 'link-14');">printing</a></tt> <tt class="py-keyword">import</tt> <tt id="link-15" class="py-name" targets="Class robotide.utils.printing.Printing=robotide.utils.printing.Printing-class.html"><a title="robotide.utils.printing.Printing" class="py-name" href="#" onclick="return doclink('link-15', 'Printing', 'link-15');">Printing</a></tt> </tt>
<a name="L29"></a><tt class="py-lineno">29</tt>  <tt class="py-line"> </tt>
<a name="L30"></a><tt class="py-lineno">30</tt>  <tt class="py-line"> </tt>
<a name="name_from_class"></a><div id="name_from_class-def"><a name="L31"></a><tt class="py-lineno">31</tt> <a class="py-toggle" href="#" id="name_from_class-toggle" onclick="return toggle('name_from_class');">-</a><tt class="py-line"><tt class="py-keyword">def</tt> <a class="py-def-name" href="robotide.utils-module.html#name_from_class">name_from_class</a><tt class="py-op">(</tt><tt class="py-param">item</tt><tt class="py-op">,</tt> <tt class="py-param">drop</tt><tt class="py-op">=</tt><tt class="py-name">None</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
</div><div id="name_from_class-collapsed" style="display:none;" pad="++" indent="++++"></div><div id="name_from_class-expanded"><a name="L32"></a><tt class="py-lineno">32</tt>  <tt class="py-line">    <tt class="py-name">cls</tt> <tt class="py-op">=</tt> <tt class="py-name">inspect</tt><tt class="py-op">.</tt><tt class="py-name">isclass</tt><tt class="py-op">(</tt><tt id="link-16" class="py-name" targets="Variable robotide.controller.commands.Occurrence.item=robotide.controller.commands.Occurrence-class.html#item,Variable robotide.ui.tree.ResourceRootHandler.item=robotide.ui.tree.ResourceRootHandler-class.html#item"><a title="robotide.controller.commands.Occurrence.item
robotide.ui.tree.ResourceRootHandler.item" class="py-name" href="#" onclick="return doclink('link-16', 'item', 'link-16');">item</a></tt><tt class="py-op">)</tt> <tt class="py-keyword">and</tt> <tt id="link-17" class="py-name"><a title="robotide.controller.commands.Occurrence.item
robotide.ui.tree.ResourceRootHandler.item" class="py-name" href="#" onclick="return doclink('link-17', 'item', 'link-16');">item</a></tt> <tt class="py-keyword">or</tt> <tt id="link-18" class="py-name"><a title="robotide.controller.commands.Occurrence.item
robotide.ui.tree.ResourceRootHandler.item" class="py-name" href="#" onclick="return doclink('link-18', 'item', 'link-16');">item</a></tt><tt class="py-op">.</tt><tt class="py-name">__class__</tt> </tt>
<a name="L33"></a><tt class="py-lineno">33</tt>  <tt class="py-line">    <tt id="link-19" class="py-name" targets="Variable robotide.contrib.testrunner.TestSuiteTreeCtrl.TreeNode.name=robotide.contrib.testrunner.TestSuiteTreeCtrl.TreeNode-class.html#name,Variable robotide.contrib.testrunner.runprofiles.CustomScriptProfile.name=robotide.contrib.testrunner.runprofiles.CustomScriptProfile-class.html#name,Variable robotide.contrib.testrunner.runprofiles.PybotProfile.name=robotide.contrib.testrunner.runprofiles.PybotProfile-class.html#name,Variable robotide.controller.settingcontrollers.ImportController.name=robotide.controller.settingcontrollers.ImportController-class.html#name,Variable robotide.controller.settingcontrollers.MetadataController.name=robotide.controller.settingcontrollers.MetadataController-class.html#name,Variable robotide.controller.settingcontrollers.VariableController.name=robotide.controller.settingcontrollers.VariableController-class.html#name,Variable robotide.controller.stepcontrollers.ForLoopStepController.name=robotide.controller.stepcontrollers.ForLoopStepController-class.html#name,Variable robotide.controller.tags.Tag.name=robotide.controller.tags.Tag-class.html#name,Variable robotide.editor.editors.EditorPanel.name=robotide.editor.editors.EditorPanel-class.html#name,Variable robotide.publish.messages.name=robotide.publish.messages-module.html#name"><a title="robotide.contrib.testrunner.TestSuiteTreeCtrl.TreeNode.name
robotide.contrib.testrunner.runprofiles.CustomScriptProfile.name
robotide.contrib.testrunner.runprofiles.PybotProfile.name
robotide.controller.settingcontrollers.ImportController.name
robotide.controller.settingcontrollers.MetadataController.name
robotide.controller.settingcontrollers.VariableController.name
robotide.controller.stepcontrollers.ForLoopStepController.name
robotide.controller.tags.Tag.name
robotide.editor.editors.EditorPanel.name
robotide.publish.messages.name" class="py-name" href="#" onclick="return doclink('link-19', 'name', 'link-19');">name</a></tt> <tt class="py-op">=</tt> <tt class="py-name">cls</tt><tt class="py-op">.</tt><tt class="py-name">__name__</tt> </tt>
<a name="L34"></a><tt class="py-lineno">34</tt>  <tt class="py-line">    <tt class="py-keyword">if</tt> <tt class="py-name">drop</tt> <tt class="py-keyword">and</tt> <tt id="link-20" class="py-name"><a title="robotide.contrib.testrunner.TestSuiteTreeCtrl.TreeNode.name
robotide.contrib.testrunner.runprofiles.CustomScriptProfile.name
robotide.contrib.testrunner.runprofiles.PybotProfile.name
robotide.controller.settingcontrollers.ImportController.name
robotide.controller.settingcontrollers.MetadataController.name
robotide.controller.settingcontrollers.VariableController.name
robotide.controller.stepcontrollers.ForLoopStepController.name
robotide.controller.tags.Tag.name
robotide.editor.editors.EditorPanel.name
robotide.publish.messages.name" class="py-name" href="#" onclick="return doclink('link-20', 'name', 'link-19');">name</a></tt><tt class="py-op">.</tt><tt class="py-name">endswith</tt><tt class="py-op">(</tt><tt class="py-name">drop</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
<a name="L35"></a><tt class="py-lineno">35</tt>  <tt class="py-line">        <tt id="link-21" class="py-name"><a title="robotide.contrib.testrunner.TestSuiteTreeCtrl.TreeNode.name
robotide.contrib.testrunner.runprofiles.CustomScriptProfile.name
robotide.contrib.testrunner.runprofiles.PybotProfile.name
robotide.controller.settingcontrollers.ImportController.name
robotide.controller.settingcontrollers.MetadataController.name
robotide.controller.settingcontrollers.VariableController.name
robotide.controller.stepcontrollers.ForLoopStepController.name
robotide.controller.tags.Tag.name
robotide.editor.editors.EditorPanel.name
robotide.publish.messages.name" class="py-name" href="#" onclick="return doclink('link-21', 'name', 'link-19');">name</a></tt> <tt class="py-op">=</tt> <tt id="link-22" class="py-name"><a title="robotide.contrib.testrunner.TestSuiteTreeCtrl.TreeNode.name
robotide.contrib.testrunner.runprofiles.CustomScriptProfile.name
robotide.contrib.testrunner.runprofiles.PybotProfile.name
robotide.controller.settingcontrollers.ImportController.name
robotide.controller.settingcontrollers.MetadataController.name
robotide.controller.settingcontrollers.VariableController.name
robotide.controller.stepcontrollers.ForLoopStepController.name
robotide.controller.tags.Tag.name
robotide.editor.editors.EditorPanel.name
robotide.publish.messages.name" class="py-name" href="#" onclick="return doclink('link-22', 'name', 'link-19');">name</a></tt><tt class="py-op">[</tt><tt class="py-op">:</tt><tt class="py-op">-</tt><tt class="py-name">len</tt><tt class="py-op">(</tt><tt class="py-name">drop</tt><tt class="py-op">)</tt><tt class="py-op">]</tt> </tt>
<a name="L36"></a><tt class="py-lineno">36</tt>  <tt class="py-line">    <tt class="py-keyword">return</tt> <tt class="py-name">printable_name</tt><tt class="py-op">(</tt><tt id="link-23" class="py-name"><a title="robotide.contrib.testrunner.TestSuiteTreeCtrl.TreeNode.name
robotide.contrib.testrunner.runprofiles.CustomScriptProfile.name
robotide.contrib.testrunner.runprofiles.PybotProfile.name
robotide.controller.settingcontrollers.ImportController.name
robotide.controller.settingcontrollers.MetadataController.name
robotide.controller.settingcontrollers.VariableController.name
robotide.controller.stepcontrollers.ForLoopStepController.name
robotide.controller.tags.Tag.name
robotide.editor.editors.EditorPanel.name
robotide.publish.messages.name" class="py-name" href="#" onclick="return doclink('link-23', 'name', 'link-19');">name</a></tt><tt class="py-op">,</tt> <tt class="py-name">code_style</tt><tt class="py-op">=</tt><tt class="py-name">True</tt><tt class="py-op">)</tt> </tt>
</div><a name="L37"></a><tt class="py-lineno">37</tt>  <tt class="py-line"> </tt>
<a name="L38"></a><tt class="py-lineno">38</tt>  <tt class="py-line"> </tt>
<a name="split_value"></a><div id="split_value-def"><a name="L39"></a><tt class="py-lineno">39</tt> <a class="py-toggle" href="#" id="split_value-toggle" onclick="return toggle('split_value');">-</a><tt class="py-line"><tt class="py-keyword">def</tt> <a class="py-def-name" href="robotide.utils-module.html#split_value">split_value</a><tt class="py-op">(</tt><tt class="py-param">value</tt><tt class="py-op">,</tt> <tt class="py-param">sep</tt><tt class="py-op">=</tt><tt class="py-string">'|'</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
</div><div id="split_value-collapsed" style="display:none;" pad="++" indent="++++"></div><div id="split_value-expanded"><a name="L40"></a><tt class="py-lineno">40</tt>  <tt class="py-line">    <tt class="py-keyword">if</tt> <tt class="py-keyword">not</tt> <tt id="link-24" class="py-name" targets="Variable robotide.controller.settingcontrollers.DocumentationController.value=robotide.controller.settingcontrollers.DocumentationController-class.html#value,Variable robotide.controller.settingcontrollers.MetadataController.value=robotide.controller.settingcontrollers.MetadataController-class.html#value,Variable robotide.controller.settingcontrollers.VariableController.value=robotide.controller.settingcontrollers.VariableController-class.html#value,Variable robotide.editor.tags.TagBox.value=robotide.editor.tags.TagBox-class.html#value"><a title="robotide.controller.settingcontrollers.DocumentationController.value
robotide.controller.settingcontrollers.MetadataController.value
robotide.controller.settingcontrollers.VariableController.value
robotide.editor.tags.TagBox.value" class="py-name" href="#" onclick="return doclink('link-24', 'value', 'link-24');">value</a></tt><tt class="py-op">:</tt> </tt>
<a name="L41"></a><tt class="py-lineno">41</tt>  <tt class="py-line">        <tt class="py-keyword">return</tt> <tt class="py-op">[</tt><tt class="py-op">]</tt> </tt>
<a name="L42"></a><tt class="py-lineno">42</tt>  <tt class="py-line">    <tt class="py-keyword">return</tt> <tt class="py-op">[</tt> <tt id="link-25" class="py-name" targets="Variable robotide.context.v=robotide.context-module.html#v"><a title="robotide.context.v" class="py-name" href="#" onclick="return doclink('link-25', 'v', 'link-25');">v</a></tt><tt class="py-op">.</tt><tt class="py-name">strip</tt><tt class="py-op">(</tt><tt class="py-op">)</tt> <tt class="py-keyword">for</tt> <tt id="link-26" class="py-name"><a title="robotide.context.v" class="py-name" href="#" onclick="return doclink('link-26', 'v', 'link-25');">v</a></tt> <tt class="py-keyword">in</tt> <tt class="py-name">_split_value</tt><tt class="py-op">(</tt><tt id="link-27" class="py-name"><a title="robotide.controller.settingcontrollers.DocumentationController.value
robotide.controller.settingcontrollers.MetadataController.value
robotide.controller.settingcontrollers.VariableController.value
robotide.editor.tags.TagBox.value" class="py-name" href="#" onclick="return doclink('link-27', 'value', 'link-24');">value</a></tt><tt class="py-op">,</tt> <tt class="py-name">sep</tt><tt class="py-op">)</tt> <tt class="py-op">]</tt> </tt>
</div><a name="L43"></a><tt class="py-lineno">43</tt>  <tt class="py-line"> </tt>
<a name="_split_value"></a><div id="_split_value-def"><a name="L44"></a><tt class="py-lineno">44</tt> <a class="py-toggle" href="#" id="_split_value-toggle" onclick="return toggle('_split_value');">-</a><tt class="py-line"><tt class="py-keyword">def</tt> <a class="py-def-name" href="robotide.utils-module.html#_split_value">_split_value</a><tt class="py-op">(</tt><tt class="py-param">value</tt><tt class="py-op">,</tt> <tt class="py-param">sep</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
</div><div id="_split_value-collapsed" style="display:none;" pad="++" indent="++++"></div><div id="_split_value-expanded"><a name="L45"></a><tt class="py-lineno">45</tt>  <tt class="py-line">    <tt class="py-keyword">if</tt> <tt class="py-string">'\\'</tt> <tt class="py-keyword">not</tt> <tt class="py-keyword">in</tt> <tt id="link-28" class="py-name"><a title="robotide.controller.settingcontrollers.DocumentationController.value
robotide.controller.settingcontrollers.MetadataController.value
robotide.controller.settingcontrollers.VariableController.value
robotide.editor.tags.TagBox.value" class="py-name" href="#" onclick="return doclink('link-28', 'value', 'link-24');">value</a></tt><tt class="py-op">:</tt> </tt>
<a name="L46"></a><tt class="py-lineno">46</tt>  <tt class="py-line">        <tt class="py-keyword">return</tt> <tt id="link-29" class="py-name"><a title="robotide.controller.settingcontrollers.DocumentationController.value
robotide.controller.settingcontrollers.MetadataController.value
robotide.controller.settingcontrollers.VariableController.value
robotide.editor.tags.TagBox.value" class="py-name" href="#" onclick="return doclink('link-29', 'value', 'link-24');">value</a></tt><tt class="py-op">.</tt><tt class="py-name">split</tt><tt class="py-op">(</tt><tt class="py-name">sep</tt><tt class="py-op">)</tt> </tt>
<a name="L47"></a><tt class="py-lineno">47</tt>  <tt class="py-line">    <tt class="py-name">ret</tt> <tt class="py-op">=</tt> <tt class="py-op">[</tt><tt class="py-op">]</tt> </tt>
<a name="L48"></a><tt class="py-lineno">48</tt>  <tt class="py-line">    <tt class="py-name">catenate_next</tt> <tt class="py-op">=</tt> <tt class="py-name">False</tt> </tt>
<a name="L49"></a><tt class="py-lineno">49</tt>  <tt class="py-line">    <tt class="py-keyword">for</tt> <tt id="link-30" class="py-name"><a title="robotide.controller.commands.Occurrence.item
robotide.ui.tree.ResourceRootHandler.item" class="py-name" href="#" onclick="return doclink('link-30', 'item', 'link-16');">item</a></tt> <tt class="py-keyword">in</tt> <tt id="link-31" class="py-name"><a title="robotide.controller.settingcontrollers.DocumentationController.value
robotide.controller.settingcontrollers.MetadataController.value
robotide.controller.settingcontrollers.VariableController.value
robotide.editor.tags.TagBox.value" class="py-name" href="#" onclick="return doclink('link-31', 'value', 'link-24');">value</a></tt><tt class="py-op">.</tt><tt class="py-name">split</tt><tt class="py-op">(</tt><tt class="py-name">sep</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
<a name="L50"></a><tt class="py-lineno">50</tt>  <tt class="py-line">        <tt class="py-name">bslash_count</tt> <tt class="py-op">=</tt> <tt class="py-name">len</tt><tt class="py-op">(</tt><tt id="link-32" class="py-name"><a title="robotide.controller.commands.Occurrence.item
robotide.ui.tree.ResourceRootHandler.item" class="py-name" href="#" onclick="return doclink('link-32', 'item', 'link-16');">item</a></tt><tt class="py-op">)</tt> <tt class="py-op">-</tt> <tt class="py-name">len</tt><tt class="py-op">(</tt><tt id="link-33" class="py-name"><a title="robotide.controller.commands.Occurrence.item
robotide.ui.tree.ResourceRootHandler.item" class="py-name" href="#" onclick="return doclink('link-33', 'item', 'link-16');">item</a></tt><tt class="py-op">.</tt><tt class="py-name">rstrip</tt><tt class="py-op">(</tt><tt class="py-string">'\\'</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
<a name="L51"></a><tt class="py-lineno">51</tt>  <tt class="py-line">        <tt class="py-name">escaped</tt> <tt class="py-op">=</tt> <tt class="py-name">bslash_count</tt> <tt class="py-op">%</tt> <tt class="py-number">2</tt> <tt class="py-op">==</tt> <tt class="py-number">1</tt> </tt>
<a name="L52"></a><tt class="py-lineno">52</tt>  <tt class="py-line">        <tt class="py-keyword">if</tt> <tt class="py-name">escaped</tt><tt class="py-op">:</tt> </tt>
<a name="L53"></a><tt class="py-lineno">53</tt>  <tt class="py-line">            <tt id="link-34" class="py-name"><a title="robotide.controller.commands.Occurrence.item
robotide.ui.tree.ResourceRootHandler.item" class="py-name" href="#" onclick="return doclink('link-34', 'item', 'link-16');">item</a></tt> <tt class="py-op">=</tt> <tt id="link-35" class="py-name"><a title="robotide.controller.commands.Occurrence.item
robotide.ui.tree.ResourceRootHandler.item" class="py-name" href="#" onclick="return doclink('link-35', 'item', 'link-16');">item</a></tt><tt class="py-op">[</tt><tt class="py-op">:</tt><tt class="py-op">-</tt><tt class="py-number">1</tt><tt class="py-op">]</tt> </tt>
<a name="L54"></a><tt class="py-lineno">54</tt>  <tt class="py-line">        <tt class="py-keyword">if</tt> <tt class="py-name">catenate_next</tt><tt class="py-op">:</tt> </tt>
<a name="L55"></a><tt class="py-lineno">55</tt>  <tt class="py-line">            <tt class="py-name">ret</tt><tt class="py-op">[</tt><tt class="py-op">-</tt><tt class="py-number">1</tt><tt class="py-op">]</tt> <tt class="py-op">+=</tt> <tt class="py-name">sep</tt> <tt class="py-op">+</tt> <tt id="link-36" class="py-name"><a title="robotide.controller.commands.Occurrence.item
robotide.ui.tree.ResourceRootHandler.item" class="py-name" href="#" onclick="return doclink('link-36', 'item', 'link-16');">item</a></tt> </tt>
<a name="L56"></a><tt class="py-lineno">56</tt>  <tt class="py-line">        <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
<a name="L57"></a><tt class="py-lineno">57</tt>  <tt class="py-line">            <tt class="py-name">ret</tt><tt class="py-op">.</tt><tt class="py-name">append</tt><tt class="py-op">(</tt><tt id="link-37" class="py-name"><a title="robotide.controller.commands.Occurrence.item
robotide.ui.tree.ResourceRootHandler.item" class="py-name" href="#" onclick="return doclink('link-37', 'item', 'link-16');">item</a></tt><tt class="py-op">)</tt> </tt>
<a name="L58"></a><tt class="py-lineno">58</tt>  <tt class="py-line">        <tt class="py-name">catenate_next</tt> <tt class="py-op">=</tt> <tt class="py-name">escaped</tt> </tt>
<a name="L59"></a><tt class="py-lineno">59</tt>  <tt class="py-line">    <tt class="py-keyword">return</tt> <tt class="py-name">ret</tt> </tt>
</div><a name="L60"></a><tt class="py-lineno">60</tt>  <tt class="py-line"> </tt>
<a name="L61"></a><tt class="py-lineno">61</tt>  <tt class="py-line"> </tt>
<a name="join_value"></a><div id="join_value-def"><a name="L62"></a><tt class="py-lineno">62</tt> <a class="py-toggle" href="#" id="join_value-toggle" onclick="return toggle('join_value');">-</a><tt class="py-line"><tt class="py-keyword">def</tt> <a class="py-def-name" href="robotide.utils-module.html#join_value">join_value</a><tt class="py-op">(</tt><tt class="py-param">value</tt><tt class="py-op">,</tt> <tt class="py-param">sep</tt><tt class="py-op">=</tt><tt class="py-string">'|'</tt><tt class="py-op">,</tt> <tt class="py-param">joiner</tt><tt class="py-op">=</tt><tt class="py-name">None</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
</div><div id="join_value-collapsed" style="display:none;" pad="++" indent="++++"></div><div id="join_value-expanded"><a name="L63"></a><tt class="py-lineno">63</tt>  <tt class="py-line">    <tt class="py-keyword">if</tt> <tt class="py-keyword">not</tt> <tt class="py-name">joiner</tt><tt class="py-op">:</tt> </tt>
<a name="L64"></a><tt class="py-lineno">64</tt>  <tt class="py-line">        <tt class="py-name">joiner</tt> <tt class="py-op">=</tt> <tt class="py-string">' %s '</tt> <tt class="py-op">%</tt> <tt class="py-name">sep</tt> </tt>
<a name="L65"></a><tt class="py-lineno">65</tt>  <tt class="py-line">    <tt class="py-keyword">return</tt> <tt class="py-name">joiner</tt><tt class="py-op">.</tt><tt class="py-name">join</tt><tt class="py-op">(</tt><tt class="py-op">[</tt> <tt id="link-38" class="py-name"><a title="robotide.context.v" class="py-name" href="#" onclick="return doclink('link-38', 'v', 'link-25');">v</a></tt><tt class="py-op">.</tt><tt class="py-name">replace</tt><tt class="py-op">(</tt><tt class="py-name">sep</tt><tt class="py-op">,</tt> <tt class="py-string">'\\'</tt><tt class="py-op">+</tt><tt class="py-name">sep</tt><tt class="py-op">)</tt> <tt class="py-keyword">for</tt> <tt id="link-39" class="py-name"><a title="robotide.context.v" class="py-name" href="#" onclick="return doclink('link-39', 'v', 'link-25');">v</a></tt> <tt class="py-keyword">in</tt> <tt id="link-40" class="py-name"><a title="robotide.controller.settingcontrollers.DocumentationController.value
robotide.controller.settingcontrollers.MetadataController.value
robotide.controller.settingcontrollers.VariableController.value
robotide.editor.tags.TagBox.value" class="py-name" href="#" onclick="return doclink('link-40', 'value', 'link-24');">value</a></tt> <tt class="py-op">]</tt><tt class="py-op">)</tt> </tt>
</div><a name="L66"></a><tt class="py-lineno">66</tt>  <tt class="py-line"> </tt>
<a name="L67"></a><tt class="py-lineno">67</tt>  <tt class="py-line"> </tt>
<a name="find_from_pythonpath"></a><div id="find_from_pythonpath-def"><a name="L68"></a><tt class="py-lineno">68</tt> <a class="py-toggle" href="#" id="find_from_pythonpath-toggle" onclick="return toggle('find_from_pythonpath');">-</a><tt class="py-line"><tt class="py-keyword">def</tt> <a class="py-def-name" href="robotide.utils-module.html#find_from_pythonpath">find_from_pythonpath</a><tt class="py-op">(</tt><tt class="py-param">name</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
</div><div id="find_from_pythonpath-collapsed" style="display:none;" pad="++" indent="++++"></div><div id="find_from_pythonpath-expanded"><a name="L69"></a><tt class="py-lineno">69</tt>  <tt class="py-line">    <tt class="py-keyword">for</tt> <tt class="py-name">dirpath</tt> <tt class="py-keyword">in</tt> <tt class="py-name">sys</tt><tt class="py-op">.</tt><tt class="py-name">path</tt><tt class="py-op">:</tt> </tt>
<a name="L70"></a><tt class="py-lineno">70</tt>  <tt class="py-line">        <tt class="py-keyword">if</tt> <tt class="py-keyword">not</tt> <tt class="py-name">os</tt><tt class="py-op">.</tt><tt class="py-name">path</tt><tt class="py-op">.</tt><tt class="py-name">isdir</tt><tt class="py-op">(</tt><tt class="py-name">dirpath</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
<a name="L71"></a><tt class="py-lineno">71</tt>  <tt class="py-line">            <tt class="py-keyword">continue</tt> </tt>
<a name="L72"></a><tt class="py-lineno">72</tt>  <tt class="py-line">        <tt class="py-name">path</tt> <tt class="py-op">=</tt> <tt class="py-name">os</tt><tt class="py-op">.</tt><tt class="py-name">path</tt><tt class="py-op">.</tt><tt class="py-name">join</tt><tt class="py-op">(</tt><tt class="py-name">dirpath</tt><tt class="py-op">,</tt> <tt id="link-41" class="py-name"><a title="robotide.contrib.testrunner.TestSuiteTreeCtrl.TreeNode.name
robotide.contrib.testrunner.runprofiles.CustomScriptProfile.name
robotide.contrib.testrunner.runprofiles.PybotProfile.name
robotide.controller.settingcontrollers.ImportController.name
robotide.controller.settingcontrollers.MetadataController.name
robotide.controller.settingcontrollers.VariableController.name
robotide.controller.stepcontrollers.ForLoopStepController.name
robotide.controller.tags.Tag.name
robotide.editor.editors.EditorPanel.name
robotide.publish.messages.name" class="py-name" href="#" onclick="return doclink('link-41', 'name', 'link-19');">name</a></tt><tt class="py-op">)</tt> </tt>
<a name="L73"></a><tt class="py-lineno">73</tt>  <tt class="py-line">        <tt class="py-keyword">if</tt> <tt class="py-name">os</tt><tt class="py-op">.</tt><tt class="py-name">path</tt><tt class="py-op">.</tt><tt class="py-name">isfile</tt><tt class="py-op">(</tt><tt class="py-name">path</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
<a name="L74"></a><tt class="py-lineno">74</tt>  <tt class="py-line">            <tt class="py-keyword">return</tt> <tt class="py-name">path</tt> </tt>
<a name="L75"></a><tt class="py-lineno">75</tt>  <tt class="py-line">    <tt class="py-keyword">return</tt> <tt class="py-name">None</tt> </tt>
</div><a name="L76"></a><tt class="py-lineno">76</tt>  <tt class="py-line"> </tt><script type="text/javascript">
<!--
expandto(location.href);
// -->
</script>
</pre>
<br />
<!-- ==================== NAVIGATION BAR ==================== -->
<table class="navbar" border="0" width="100%" cellpadding="0"
       bgcolor="#a0c0ff" cellspacing="0">
  <tr valign="middle">
  <!-- Home link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="robotide-module.html">Home</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Tree link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="module-tree.html">Trees</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Index link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="identifier-index.html">Indices</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Help link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="help.html">Help</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Project homepage -->
      <th class="navbar" align="right" width="100%">
        <table border="0" cellpadding="0" cellspacing="0">
          <tr><th class="navbar" align="center"
            ><a class="navbar" target="_top" href="http://code.google.com/p/robotframework-ride">RIDE</a></th>
          </tr></table></th>
  </tr>
</table>
<table border="0" cellpadding="0" cellspacing="0" width="100%%">
  <tr>
    <td align="left" class="footer">
    Generated by Epydoc 3.0.1 on Wed Apr 13 15:09:48 2011
    </td>
    <td align="right" class="footer">
      <a target="mainFrame" href="http://epydoc.sourceforge.net"
        >http://epydoc.sourceforge.net</a>
    </td>
  </tr>
</table>

<script type="text/javascript">
  <!--
  // Private objects are initially displayed (because if
  // javascript is turned off then we want them to be
  // visible); but by default, we want to hide them.  So hide
  // them unless we have a cookie that says to show them.
  checkCookie();
  // -->
</script>
</body>
</html>
